package cn.java79.springboot.zsb.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * @author oldliu
 * @since 1.0
 */
@Data
@NoArgsConstructor
@ToString
@TableName("s_user")
@ApiModel("用户")
public class User implements Serializable {
    @TableId(type = IdType.AUTO)
    @ApiModelProperty("编号，新增时自动生成")
    private Long id;
    @ApiModelProperty("姓名")
    private String sname;
    @ApiModelProperty("学校")
    private String school;
    @ApiModelProperty("专业")
    private String major;
    @ApiModelProperty("学校类型，是专科或者高职等")
    private String type;
    @ApiModelProperty("微信openid")
    private String openid;
    @ApiModelProperty("手机号")
    private String phone;
    @ApiModelProperty("性别")
    private String sex;
    @ApiModelProperty("地址")
    private String addr;
    @ApiModelProperty("密码")
    private String pass;
    @ApiModelProperty("是否已经毕业")
    boolean isgraduate;
    @ApiModelProperty("加入时间，默认是当前时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date addtime;

}
